/*
 * Foogl (Friendly Object Oriented Game Library)
 * Copyright (c) 2008 Wachirawut Thamviset.
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Lesser General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

package kku.cs.fgl;

import java.io.InputStream;

import org.newdawn.slick.*;
/**
 * A font implementation that will parse the output of the AngelCode font tool available at:
 * 
 * <a href="http://www.angelcode.com/products/bmfont/">http://www.angelcode.com/products/bmfont/</a>
 *
 * This implementation copes with both the font display and kerning information allowing nicer
 * looking paragraphs of text. Note that this utility only supports the xml format definition
 * file.
 * 
 * @author kevin
 */
public class BMFont extends AngelCodeFont {

	final String fontPath="font/";
	/**
	 * Create a new font based on a font definition from AngelCode's tool and the font
	 * image generated from the tool.
	 * 
	 * @param fntFile The location of the font defnition file
	 * @throws SlickException 
	 */
	public BMFont(String fntFile) throws SlickException {
		super("font/"+fntFile+".fnt","font/"+fntFile+"_00.png");
	}
	public BMFont(int id) throws SlickException {
		this("font"+id);		
	}
	public BMFont(String fntFile, Image image, boolean caching) throws SlickException {
		super(fntFile, image, caching);
	}
	public BMFont(String fntFile, Image image) throws SlickException {
		super(fntFile, image);
	}
	public BMFont(String name, InputStream fntFile, InputStream imgFile, boolean caching) throws SlickException {
		super(name, fntFile, imgFile, caching);
	}
	public BMFont(String name, InputStream fntFile, InputStream imgFile) throws SlickException {
		super(name, fntFile, imgFile);
	}
	public BMFont(String fntFile, String imgFile, boolean caching) throws SlickException {
		super(fntFile, imgFile, caching);
	}
	public BMFont(String fntFile, String imgFile) throws SlickException {
		super(fntFile, imgFile);
	}
	
}
